]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
workspacesView: initialize self._restackedNotifyId
authorWill Thompson <will@willthompson.co.uk>
Tue, 25 Sep 2018 22:00:53 +0000 (23:00 +0100)
committerWill Thompson <will@willthompson.co.uk>
Tue, 25 Sep 2018 22:00:53 +0000 (23:00 +0100)
This attribute was previously only assigned in show(). hide() compares
this attribute to 0. If hide() is called before show() is first called,
the comparison would give the correct result (undefined > 0 is false)
but log a warning:

    JS WARNING: [resource:///org/gnome/shell/ui/workspacesView.js 529]:
    reference to undefined property "_restackedNotifyId"

Initialize this attribute in _init(), alongside _scrollEventId and
_keyPressEventId which are also used in hide().

js/ui/workspacesView.js

index 4ba8db754878ee0ef6e79d67ba83cd3305ec9afb..4c97094aaadbd02aa977a12d89714e425db5fd41 100644 (file)
@@ -481,6 +481,7 @@ var WorkspacesDisplay = new Lang.Class({
         this._switchWorkspaceNotifyId = 0;
 
         this._notifyOpacityId = 0;
+        this._restackedNotifyId = 0;
         this._scrollEventId = 0;
         this._keyPressEventId = 0;